#!/bin/bash

pip install layoutparser

# To use newly generated models rather than original model, switch config and model path in large for loop from "Two Meetings/From Manuscript" to "Two Meetings/Replication" in the "Data Extraction.ipynb" file. Then run this bash script from the command line WITHIN docker using the command "bash 'Step 4/Step 4.sh'" 

# Converts ipynb to py and runs python script
chmod +x 'Step 4/Data Extraction.ipynb'

jupyter nbconvert --to python 'Step 4/Data Extraction.ipynb'

python3 'Step 4/Data Extraction.py'

# The extracted agenda items in excel necessary to generate the figures from the manuscript can be found in the Data Extraction folder. When carrying out the process yourself, these will be written over when you run this bash script.
